package com.imooc.dao;

import com.imooc.dataobject.ProductInfo;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created by MisterDeng on 2018/5/14/014 13:16.
 */
@Repository
public interface ProductInfoMapper {
    int updateStockByProductId(ProductInfo info);

    @Select("select * from product_info where product_id = #{productId}")
    ProductInfo findByProductId(String productId);

    List<String> findAll();

    void save(ProductInfo info);
}
